﻿@inject Microsoft.AspNetCore.Http.IHttpContextAccessor _httpContextAccessor

@{
    var name = _httpContextAccessor.HttpContext?.User?.Claims?.FirstOrDefault(c => c.Type == System.Security.Claims.ClaimTypes.GivenName)?.Value ?? "您还没有登陆";
}

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>@ViewData["Title"] - 项目管理系统</title>

    @*<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@3.4.1/dist/css/bootstrap.min.css">
        <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/font-awesome@4.7.0/css/font-awesome.min.css">
        <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/viewerjs@1.9.0/dist/viewer.min.css">
        <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@adactive/bootstrap-tagsinput@0.8.2/dist/bootstrap-tagsinput.css">
        <link rel="stylesheet" href="https://cdn.bootcdn.net/ajax/libs/twitter-bootstrap/3.4.1/css/bootstrap.min.css">
        <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.3.0/font/bootstrap-icons.css">
        <link rel="stylesheet" href="https://cdn.bootcdn.net/ajax/libs/bootstrap-icons/1.2.1/bootstrap-icons.svg">
        <link rel="stylesheet" href="https://cdn.bootcdn.net/ajax/libs/bootstrap-tagsinput/0.8.0/bootstrap-tagsinput.css" rel="stylesheet">
        <link rel="stylesheet" href="https://cdn.bootcdn.net/ajax/libs/bootstrap-tagsinput/0.8.0/bootstrap-tagsinput-typeahead.css" rel="stylesheet">
        <link rel="stylesheet" href="https://cdn.devonline.cn/kendoui/dist/styles/web/kendo.common-bootstrap.css" />
        <link rel="stylesheet" href="https://cdn.devonline.cn/kendoui/dist/styles/web/kendo.bootstrap.css" />
        <link rel="stylesheet" href="https://cdn.devonline.cn/kendoui/dist/styles/web/kendo.common.css" />
        <link rel="stylesheet" href="https://cdn.devonline.cn/devonline/css/com.css" />*@

    <!-- 开发阶段使用本地资源, 发布后使用 CDN -->
    <link rel="stylesheet" href="~/lib/bootstrap/dist/css/bootstrap.min.css">
    <link rel="stylesheet" href="~/lib/font-awesome/css/font-awesome.min.css">
    <link rel="stylesheet" href="~/lib/viewerjs/dist/viewer.min.css">
    <link rel="stylesheet" href="~/lib/kendoui/styles/web/kendo.common-bootstrap.css" />
    <link rel="stylesheet" href="~/lib/kendoui/styles/web/kendo.bootstrap.css" />
    <link rel="stylesheet" href="~/lib/kendoui/styles/web/kendo.common.css" />
    <link rel="stylesheet" href="~/lib/devonline/css/com.css" />
</head>
<body>
    <header class="header body-content">
        <nav class="navbar navbar-default header-navigation">
            <a class="navbar-brand" asp-area="" asp-controller="Home" asp-action="Index">项目管理系统</a>

            <ul class="nav navbar-nav navbar-right">
                <li class="nav-item">
                    <a class="nav-link text-dark" asp-area="" asp-controller="Home" asp-action="Profile">[@name]</a>
                </li>
                <li class="nav-item">
                    <a class="nav-link text-dark" href="#" onclick="Account.onLogout(this)">[注销]</a>
                </li>
            </ul>

            <ul class="nav nav-pills">
                <li class="presentation">
                    <a class="nav-link text-dark" asp-area="" asp-controller="Home" asp-action="Index">首页</a>
                </li>
                <li class="nav-item">
                    <a class="nav-link text-dark" asp-area="" asp-controller="Home" asp-action="Parameter">基础数据</a>
                </li>
                <li class="nav-item">
                    <a class="nav-link text-dark" asp-area="" asp-controller="Home" asp-action="User">用户</a>
                </li>
                <li class="nav-item">
                    <a class="nav-link text-dark" asp-area="" asp-controller="Home" asp-action="Item">工作事项</a>
                </li>
                <li class="nav-item">
                    <a class="nav-link text-dark" asp-area="" asp-controller="Home" asp-action="Issue">问题记录</a>
                </li>
            </ul>
        </nav>
    </header>
    <div class="body-container body-content">
        @RenderBody()
    </div>

    <footer class="border-top footer text-center">
        <div class="container">
            &copy; 2020-@DateTime.Now.Year - 项目管理系统
        </div>
    </footer>

    <partial name="_Template" />

    <!-- CDN -->
    <!-- cdn.jsdelivr.net -->
    @*<script src="https://cdn.jsdelivr.net/npm/jquery@3.5.1/dist/jquery.min.js"></script>
        <script src="https://cdn.jsdelivr.net/npm/bootstrap@3.4.1/dist/js/bootstrap.min.js"></script>
        <script src="https://cdn.jsdelivr.net/npm/axios@0.21.1/dist/axios.min.js"></script>
        <script src="https://cdn.jsdelivr.net/npm/underscore@1.12.0/underscore.min.js"></script>
        <script src="https://cdn.jsdelivr.net/npm/underscore.string@3.3.5/dist/underscore.string.min.js"></script>
        <script src="https://cdn.jsdelivr.net/npm/moment@2.29.1/min/moment-with-locales.min.js"></script>
        <script src="https://cdn.jsdelivr.net/npm/moment-timezone@0.5.32/builds/moment-timezone-with-data.min.js"></script>
        <script src="https://cdn.jsdelivr.net/npm/sweetalert@2.1.2/dist/sweetalert.min.js"></script>
        <script src="https://cdn.jsdelivr.net/npm/viewerjs@1.9.0/dist/viewer.min.js"></script>
        <script src="https://cdn.jsdelivr.net/npm/jquery-viewer@1.0.1/dist/jquery-viewer.min.js"></script>
        <script src="https://cdn.jsdelivr.net/npm/downloadjs@1.4.7/download.min.js"></script>*@

    <!-- cdn.bootcdn.net -->
    <!--<script src="https://cdn.bootcdn.net/ajax/libs/jquery/3.5.1/jquery.min.js"></script>
    <script src="https://cdn.bootcdn.net/ajax/libs/twitter-bootstrap/3.4.1/js/bootstrap.min.js"></script>
    <script src="https://cdn.bootcdn.net/ajax/libs/underscore.js/1.11.0/underscore.min.js"></script>
    <script src="https://cdn.bootcdn.net/ajax/libs/underscore.string/3.3.5/underscore.string.min.js"></script>
    <script src="https://cdn.bootcdn.net/ajax/libs/axios/0.21.0/axios.min.js"></script>
    <script src="https://cdn.bootcdn.net/ajax/libs/moment.js/2.29.1/moment-with-locales.min.js"></script>
    <script src="https://cdn.bootcdn.net/ajax/libs/moment-timezone/0.5.32/moment-timezone-with-data.min.js"></script>
    <script src="https://cdn.bootcdn.net/ajax/libs/sweetalert/2.1.2/sweetalert.min.js"></script>-->
    @*
        <script src="https://cdn.jsdelivr.net/npm/clipboard@2.0.6/dist/clipboard.min.js"></script>
        <script src="https://cdn.jsdelivr.net/npm/@adactive/bootstrap-tagsinput@0.8.2/dist/bootstrap-tagsinput.min.js"></script>
        <script src="https://cdn.bootcdn.net/ajax/libs/clipboard.js/2.0.6/clipboard.min.js"></script>
        <script src="https://cdn.bootcdn.net/ajax/libs/bootstrap-tagsinput/0.8.0/bootstrap-tagsinput.min.js"></script>
    *@

    @*<script src="https://cdn.devonline.cn/kendoui/dist/js/kendo.web.min.js"></script>
        <script src="https://cdn.devonline.cn/kendoui/dist/js/cultures/kendo.culture.zh-CN.js"></script>
        <script src="https://cdn.devonline.cn/kendoui/dist/js/messages/kendo.messages.zh-CN.js"></script>*@

    @*<script src="https://cdn.devonline.cn/devonline/js/com.js"></script>
        <script src="https://cdn.devonline.cn/devonline/js/extensions.js"></script>
        <script src="https://cdn.devonline.cn/devonline/js/api.js"></script>
        <script src="https://cdn.devonline.cn/devonline/js/localCache.js"></script>
        <script src="https://cdn.devonline.cn/devonline/js/config.js"></script>
        <script src="https://cdn.devonline.cn/devonline/js/app.js"></script>

        <script src="https://cdn.devonline.cn/devonline/js/plugins/jquery.plugin.js"></script>
        <script src="https://cdn.devonline.cn/devonline/js/plugins/jquery.field.js"></script>
        <script src="https://cdn.devonline.cn/devonline/js/plugins/jquery.button.js"></script>
        <script src="https://cdn.devonline.cn/devonline/js/plugins/jquery.form.js"></script>
        <script src="https://cdn.devonline.cn/devonline/js/plugins/jquery.grid.js"></script>
        <script src="https://cdn.devonline.cn/devonline/js/plugins/jquery.popup.js"></script>
        <script src="https://cdn.devonline.cn/devonline/js/plugins/jquery.showbox.js"></script>*@

    <script src="~/lib/jquery/dist/jquery.min.js"></script>
    <script src="~/lib/bootstrap/dist/js/bootstrap.min.js"></script>
    <script src="~/lib/axios/dist/axios.min.js"></script>
    <script src="~/lib/underscore/underscore-min.js"></script>
    <script src="~/lib/underscore.string/dist/underscore.string.min.js"></script>
    <script src="~/lib/moment/min/moment-with-locales.min.js"></script>
    <script src="~/lib/moment-timezone/builds/moment-timezone-with-data.min.js"></script>
    <script src="~/lib/sweetalert/dist/sweetalert.min.js"></script>
    <script src="~/lib/viewerjs/dist/viewer.min.js"></script>
    <script src="~/lib/jquery-viewer/dist/jquery-viewer.min.js"></script>
    <script src="~/lib/downloadjs/download.min.js"></script>

    <script src="~/lib/kendoui/js/kendo.web.min.js"></script>
    <script src="~/lib/kendoui/js/cultures/kendo.culture.zh-CN.js"></script>
    <script src="~/lib/kendoui/js/messages/kendo.messages.zh-CN.js"></script>

    <script src="~/lib/devonline/js/com.js"></script>
    <script src="~/lib/devonline/js/extensions.js"></script>
    <script src="~/lib/devonline/js/config.js"></script>
    <script src="~/lib/devonline/js/api.js"></script>
    <script src="~/lib/devonline/js/localCache.js"></script>
    <script src="~/lib/devonline/js/app.js"></script>

    <script src="~/lib/devonline/js/plugins/jquery.plugin.js"></script>
    <script src="~/lib/devonline/js/plugins/jquery.field.js"></script>
    <script src="~/lib/devonline/js/plugins/jquery.button.js"></script>
    <script src="~/lib/devonline/js/plugins/jquery.form.js"></script>
    <script src="~/lib/devonline/js/plugins/jquery.grid.js"></script>
    <script src="~/lib/devonline/js/plugins/jquery.popup.js"></script>
    <script src="~/lib/devonline/js/plugins/jquery.showbox.js"></script>

    <script src="~/js/site.js" asp-append-version="true"></script>
    <script src="~/js/cache.js" asp-append-version="true"></script>
    <script type="text/javascript">
        $(() => {
            app.loading.set(0, () => cache.load());
            app.startup();
        });
    </script>
    @RenderSection("Scripts", required: false)
</body>
</html>
